package com.crm.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.crm.entity.CrmProjectItem;
import com.crm.mapper.CrmProjectItemMapper;
import com.crm.service.ICrmProjectItemService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author CRM_SYSTEM
 * @since 2022-03-30
 */
@Service
public class CrmProjectItemServiceImpl extends ServiceImpl<CrmProjectItemMapper, CrmProjectItem> implements ICrmProjectItemService {

    @Override
    public List<CrmProjectItem> getByProjectCode(Long projectId) {
        return  this.list(new LambdaQueryWrapper<CrmProjectItem>()
        .eq(CrmProjectItem::getProjectId,projectId)
        .eq(CrmProjectItem::getIsDeleted,0));

    }
}
